using System.Windows.Forms;
using System.Drawing;

namespace VsxFactory.Modeling.VisualStudio.Wizards
{
    /// <summary>
    /// Wizard base page (must have a 350x290 pixels size)
    /// </summary>
    public partial class BaseWizardPage : UserControl
    {
        private string _headerText;
        private BaseWizardForm _wizard;

        private BaseWizardPage()
        {
        }

        /// <summary>
        /// Initializes a new instance of the <see cref="CandleWizardPage"/> class.
        /// </summary>
        /// <param name="parent">The parent.</param>
        public BaseWizardPage(BaseWizardForm parent)
        {
            _wizard = parent;
        }

        /// <summary>
        /// Provide the associated image (optimum size 155x290)
        /// </summary>
        /// <returns></returns>
        internal virtual Image GetWatermarkPicture()
        {
            return Wizard.GetDefaultWatermarkPicture();
        }

        /// <summary>
        /// Gets or sets the wizard.
        /// </summary>
        /// <value>The wizard.</value>
        protected BaseWizardForm Wizard
        {
            get { return _wizard; }
            set { _wizard = value; }
        }

        /// <summary>
        /// Gets or sets the header text.
        /// </summary>
        /// <value>The header text.</value>
        public string HeaderText
        {
            get { return _headerText; }
            set { _headerText = value; }
        }

        /// <summary>
        /// Called when [activated].
        /// </summary>
        public virtual void OnActivated()
        {
        }

        /// <summary>
        /// Called when [deactivated].
        /// </summary>
        /// <param name="finish">if set to <c>true</c> [finish].</param>
        /// <returns></returns>
        public virtual bool OnDeactivated(bool finish)
        {
            return true;
        }
    }
}